Skip to content

Conversation

@frankiegillis
Copy link
Contributor

This adds the function DigraphMinimumCutSet using the DigraphMaximumFlow method and the max-flow min-cut theorem. See issue #867.

…ough all triples of vertices, and instead checks center vertices of 2-edges
@mtorpey mtorpey added the WIP Label of PRs that are a Work In Progress (WIP) label Nov 5, 2025
Copy link
Collaborator

@reiniscirpons reiniscirpons left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the contribution, looks solid, some suggestions for docs and performance above, mostly minor.

In addition to the comments above, it looks like doc for the function is not linked in the manual, you should add

    <#Include Label="DigraphMinimumCut">

to z-chap5.xml in the appropriate location to get your documentation to show up in the manual (you can test this by seeing if ?DigraphMinimumCut finds the doc inside of gap).

I would also suggest changing the name of the function to DigraphMinimumCut since what its computing is the cut not the cut-set (see the definitions in https://en.wikipedia.org/wiki/Max-flow_min-cut_theorem#Cuts). It might also be good to implement a separate DigraphMinimumCutSet which wraps your current function and computes the edges.

@frankiegillis
Copy link
Contributor Author

@reiniscirpons

@reiniscirpons
Copy link
Collaborator

Looks good to me, thanks again for the contribution @frankiegillis !

I made a minor correction to the docs just now: minimal and minimum mean slightly different things. So minimal is more akin of a local minimum, i.e. there is no way to make it smaller by swapping a single point between the partitions in this context). Ill way for the CI to pass and then its good to merge!

@reiniscirpons reiniscirpons added merge-in-to-master A label for PRs that should be merged into the master branch VIP Pull requests done by participants of the VIP programme. and removed WIP Label of PRs that are a Work In Progress (WIP) labels Dec 4, 2025
@reiniscirpons reiniscirpons merged commit 8af98e6 into digraphs:main Dec 4, 2025
31 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merge-in-to-master A label for PRs that should be merged into the master branch VIP Pull requests done by participants of the VIP programme.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants